<!doctype html>
<html><!-- InstanceBegin template="/Templates/dwt.dwt" codeOutsideHTMLIsLocked="false" -->
<head>
    <meta charset="utf-8">
    <!-- InstanceBeginEditable name="doctitle" -->
    <title>谋刻职业教育在线测评与学习平台</title>
    <link rel="stylesheet" href="css/course.css"/>
    <link rel="stylesheet" href="css/member.css"/>
    <script src="js/jquery-1.8.0.min.js"></script>
    <link rel="stylesheet" href="css/tab.css" media="screen">
    <script src="js/jquery.tabs.js"></script>
    <script src="js/mine.js"></script>
    <script type="text/javascript">
        $(function(){


            $('.demo2').Tabs({
                event:'click'
            });



        });
    </script>
    <!-- InstanceEndEditable -->
    <!-- InstanceBeginEditable name="head" -->
    <!-- InstanceEndEditable -->

</head>

<body>
<div id="app">
    <div class="head" id="fixed">
        <div class="nav">
            <span class="navimg"><a href="index.html"><img border="0" src="images/logo.png"></a></span>
            <ul class="nag">
                <li><a href="courselist.html" class="link1 current">课程</a></li>
                <li><a href="articlelist.html" class="link1">资讯</a></li>
                <li><a href="teacherList.html" class="link1">讲师</a></li>
                <li><a href="exam_index.html" class="link1" target="_blank">题库</a></li>
                <li><a href="askarea.html" class="link1" target="_blank">问答</a></li>

            </ul>
            <span class="massage">
            <!--<span class="select">
        	<a href="#" class="sort">课程</a>
        	<input type="text" value="关键字"/>
            <a href="#" class="sellink"></a>
            <span class="sortext">
            	<p>课程</p>
                <p>题库</p>
                <p>讲师</p>
            </span>
        </span>-->
                <!--未登录-->
        	<span class="exambtn_lore">

                 <a class="tkbtn tklog" href="login.html">退出</a>

            </span>
                <!--登录后-->
                <!--<div class="logined">
                    <a href="mycourse.html"  onMouseOver="logmine()" style="width:70px" class="link2 he ico" target="_blank">sherley</a>
                    <span id="lne" style="display:none" onMouseOut="logclose()" onMouseOver="logmine()">
                        <span style="background:#fff;">
                            <a href="mycourse.html" style="width:70px; display:block;" class="link2 he ico" target="_blank">sherley</a>
                        </span>
                        <div class="clearh"></div>
                        <ul class="logmine" >
                            <li><a class="link1" href="#">我的课程</a></li>
                            <li><a class="link1" href="#">我的题库</a></li>
                            <li><a class="link1" href="#">我的问答</a></li>
                            <li><a class="link1" href="#">退出</a></li>
                        </ul>
                    </span>
                </div>-->

        </span>
        </div>
    </div>
    <!-- InstanceBeginEditable name="EditRegion1" -->
    <div class="clearh"></div>
    <div class="membertab">
        <div class="memblist">
            <div class="membhead">
                <div style="text-align:center;"><img :src="'/api/education-user/student/download/'+user.picImg" width="80" ></div>
                <div style="width:220px;text-align:center;">
                    <p class="membUpdate mine">{{user.showName}}</p>
                    <p class="membUpdate mine"><a href="mysetting.html">修改信息</a>&nbsp;|&nbsp;<a href="myrepassword.html">修改密码</a></p>
                    <div class="clearh"></div>
                </div>
            </div>
            <div class="memb">

                <ul>
                    <li><a class="mb1" href="mycourse.html">我的课程</a></li>
                    <li><a class="mb3" href="orderList.html">我的订单</a></li>
                    <li  class="currnav"><a class="mb4" href="mynote.html">我的笔记</a></li>
                    <li><a class="mb12" href="myhomework.html">我的作业</a></li>
                    <li><a class="mb2" href="training_list.html" target="_blank">我的题库</a></li>
                </ul>

            </div>


        </div>


        <div class="membcont">
            <h3 class="mem-h3">我的笔记</h3>
            <div class="box demo2" style="width:820px;">
                <div class="tab_box">
                    <div>
                        <table frame=box border=1>
                            <tr>
                                <!-- <td>编号</td>-->
                                <td width="50px">编号</td>

                                <td width="200px">更新时间</td>
                                <td width="100px">状态</td>
                                <td width="100px">操作</td>
                            </tr>
                            <tr v-for="(item,index) in courseList">
                                <td width="50px">{{index+1}}</td>

                                <td width="200px">{{item.updateTime |orderTimes}}</td>

                                <td width="100px">{{item.status |stateFit}}</td>
                                <td width="100px"><button  @click="looknode(item.content)">查看内容</button></td>
                            </tr>
                        </table>
                    </div>

                </div>
            </div>
        </div>
        <div class="memblist">
            <textarea v-model="nodea" rows="7" class="pingjia_con" style="width:100%;height:500px;" onblur="if (this.value =='') this.value='记下课程笔记';this.className='pingjia_con'" onclick="if (this.value=='记下课程笔记') this.value='';this.className='pingjia_con_on'">记下课程笔记</textarea>
        </div>


        <div class="clearh"></div>
    </div>

    <!-- InstanceEndEditable -->


    <div class="clearh"></div>
    <div class="foot">
        <div class="fcontainer">
            <div class="fwxwb">
                <div class="fwxwb_1">
                    <span>关注微信</span><img width="95" alt="" src="images/num.png">
                </div>
                <div>
                    <span>关注微博</span><img width="95" alt="" src="images/wb.png">
                </div>
            </div>
            <div class="fmenu">
                <p><a href="#">关于我们</a> | <a href="#">联系我们</a> | <a href="#">优秀讲师</a> | <a href="#">帮助中心</a> | <a href="#">意见反馈</a> | <a href="#">加入我们</a></p>
            </div>
            <div class="copyright">
                <div><a href="/">谋刻网</a>所有&nbsp;晋ICP备12006957号-9</div>
            </div>
        </div>
    </div>
    <!--右侧浮动-->
    <div class="rmbar">
	<span class="barico qq" style="position:relative">
	<div  class="showqq">
	   <p>官方客服QQ:<br>335049335</p>
	</div>
	</span>
        <span class="barico em" style="position:relative">
	  <img src="images/num.png" width="75" class="showem">
	</span>
        <span class="barico wb" style="position:relative">
	  <img src="images/wb.png" width="75" class="showwb">
	</span>
        <span class="barico top" id="top">置顶</span>
    </div>
</div>
</body>

<!-- InstanceEnd --></html>


<script src="js/axios.min.js"></script>
<script src="js/moment.js"></script>
<!--引入 element-ui 的样式，-->
<link rel="stylesheet" href="https://unpkg.com/element-ui/lib/theme-chalk/index.css">
<!-- 必须先引入vue，  后使用element-ui -->
<script src="https://cdn.jsdelivr.net/npm/vue@2.5.17/dist/vue.js"></script>
<!-- 引入element 的组件库-->
<script src="https://unpkg.com/element-ui/lib/index.js"></script>

<script>
    new Vue({
        el:"#app",
        data:{
            courseList:[],
            user:{},
            nodea:'',
        },
        methods:{
            list:function () {
                axios.get("/api/education-resouse/nodes/list/"+this.user.id).then(
                    (res)=>{
                        if(res.data.result!=null){
                                this.courseList=res.data.result;
                        }else {
                            this.$message({
                                showClose: true,
                                message: "您还没有笔记,请在学习过程中进行记录吧",
                                type: 'error'
                            });
                        }
                    }
                );
            },
            toHtml:function(id){
                location.href="coursecont1.html?id="+id;
            },
            looknode:function (nodeas) {
                debugger;
                if(nodeas!=null){
                    this.nodea=nodeas;
                }else {
                    this.$message({
                        showClose: true,
                        message: "抱歉，该笔记没有内容",
                        type: 'error'
                    });
                }

            }

        },
        mounted(){
            this.user = JSON.parse(sessionStorage.getItem("user"));
            if(this.user!=null) {
                this.list();
            }else{
                alert("请先登录!");
                location.href="login.html";
            }
        },
        filters:{
            stateFit:function (val) {
                if(val=='0'){
                    return '公开';
                }
                if(val=='1'){
                    return '隐藏';
                }

            },
            orderTimes:function (val) {
                    return moment(val).format("YYYY-MM-DD hh:mm:ss");
            }
        }
    });
</script>
